package com.design.装饰器模式;

/**
 * @author: sun.hongliang
 * @create: 2019/08/15 12:17
 */
public class Main {

    public static void main(String[] args) {
        Shap circle = new Circle();

        ShapeDecorator redCircle = new RedShapeDecorator(new Circle());
        ShapeDecorator redRectangle = new RedShapeDecorator(new Rectangle());
        System.out.println("Circle with normal border");
        circle.draw();

        System.out.println("\nCircle of red border");
        redCircle.draw();

        System.out.println("\nRectangle of red border");
        redRectangle.draw();
    }
}
